﻿<%@ Control Language="VB" AutoEventWireup="false" CodeFile="Beneficiarios.ascx.vb"
    Inherits="Content_Administracion_Adm_controls_Beneficiarios" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<asp:ScriptManager ID="ScriptManager1" runat="server">
</asp:ScriptManager>
<div class="titulos">
    <asp:Label ID="lbl_headerCot" runat="server" Text="Administración de Beneficiarios"></asp:Label>
</div>
<div id="Div2" class="divContent" runat="server">
    <center>
        <table style="width: 70%;">
            <tr>
                <td rowspan="15">
                    <asp:GridView ID="gv_Bene" runat="server" AllowPaging="True" 
                        AlternatingRowStyle-CssClass="GridviewAlt" AutoGenerateColumns="False" 
                        CellPadding="5" CssClass="Gridview" FooterStyle-CssClass="HeaderFooterGridview" 
                        GridLines="None" HeaderStyle-CssClass="HeaderFooterGridview" 
                        PagerStyle-CssClass="PagerColor" PageSize="8" Width="90%">
                        <Columns>
                            <asp:TemplateField ShowHeader="False">
                                <ItemTemplate>
                                    <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="False" 
                                        CommandArgument='<%# Bind("ben_id") %>' CommandName="editarBen" Text="Editar"></asp:LinkButton>
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:TemplateField ShowHeader="False">
                                <ItemTemplate>
                                    <asp:LinkButton ID="LinkButton2" runat="server" CausesValidation="False" 
                                        CommandArgument='<%# Bind("ben_id") %>' CommandName="eliminarBen" 
                                        Text="Eliminar"></asp:LinkButton>
                                    <asp:ConfirmButtonExtender ID="ConfirmButtonExtender1" runat="server" 
                                        ConfirmText="¿Estas seguro de eliminar el registro?" 
                                        TargetControlID="LinkButton2">
                                    </asp:ConfirmButtonExtender>
                                </ItemTemplate>
                            </asp:TemplateField>
                            <asp:BoundField DataField="NombreBen" HeaderText="NOMBRE" />
                            <asp:BoundField DataField="ben_parentesco" HeaderText="PARENTESCO" />
                            <asp:BoundField DataField="ben_porcentaje" HeaderText="PORCENTAJE" />
                        </Columns>
                    </asp:GridView>
                </td>
                <td>
                    <asp:Label ID="lNomBen" runat="server" Text="Nombre: " Visible="True"></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="nomBen" runat="server" ValidationGroup="g1" MaxLength="45"></asp:TextBox>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator61" runat="server" Display="None"
                        ControlToValidate="nomBen" ErrorMessage="Campo obligatorio" ForeColor="Red" ValidationGroup="g1"></asp:RequiredFieldValidator>
                    <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender60" runat="server" CloseImageUrl="~/images/close.gif"
                        CssClass="validatorCallout" HighlightCssClass="validatorCalloutHighlight" TargetControlID="RequiredFieldValidator61"
                        WarningIconImageUrl="~/images/Warning.png" />
                    <asp:FilteredTextBoxExtender ID="FilteredTextBoxExtender3" runat="server" FilterType="LowercaseLetters,UppercaseLetters,Custom"
                        ValidChars=" .ñÑáéíóúÁÉÍÓÚ" TargetControlID="nomBen">
                    </asp:FilteredTextBoxExtender>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="lAPBen" runat="server" Text="Apellido Paterno: " Visible="True"></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="apBen" runat="server" Visible="True" ValidationGroup="g1" MaxLength="45"></asp:TextBox>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator62" ValidationGroup="g1" runat="server"
                        Display="None" ControlToValidate="apBen" ErrorMessage="Campo obligatorio" ForeColor="Red"></asp:RequiredFieldValidator>
                    <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender61" runat="server" CloseImageUrl="~/images/close.gif"
                        CssClass="validatorCallout" HighlightCssClass="validatorCalloutHighlight" TargetControlID="RequiredFieldValidator62"
                        WarningIconImageUrl="~/images/Warning.png" Enabled="True" />
                    <asp:FilteredTextBoxExtender ID="FilteredTextBoxExtender1" runat="server" FilterType="LowercaseLetters,UppercaseLetters,Custom"
                        ValidChars=" .ñÑáéíóúÁÉÍÓÚ" TargetControlID="apBen">
                    </asp:FilteredTextBoxExtender>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="lAMBen" runat="server" Text="Apellido Materno: " Visible="True"></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="amBen" runat="server" Visible="True" ValidationGroup="g1" MaxLength="45"></asp:TextBox>
                    <asp:FilteredTextBoxExtender ID="FilteredTextBoxExtender2" runat="server" FilterType="LowercaseLetters,UppercaseLetters,Custom"
                        ValidChars=" .ñÑáéíóúÁÉÍÓÚ" TargetControlID="amBen">
                    </asp:FilteredTextBoxExtender>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="lfechaNacBen" runat="server" Text="Fecha de nacimiento: " Visible="True"></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="fechaNacBen" runat="server" Visible="True" ValidationGroup="g1"></asp:TextBox>
                    <asp:ImageButton ID="img_cal3" runat="server" ImageUrl="~/images/calendar.gif" />
                    <asp:CalendarExtender ID="calendar3" runat="server" Format="yyyy-MM-dd" PopupButtonID="img_cal3"
                        TargetControlID="fechaNacBen" Enabled="True">
                    </asp:CalendarExtender>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator64" ValidationGroup="g1" runat="server"
                        Display="None" ControlToValidate="fechaNacBen" ErrorMessage="Campo obligatorio"
                        ForeColor="Red"></asp:RequiredFieldValidator>
                    <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender63" runat="server" CloseImageUrl="~/images/close.gif"
                        CssClass="validatorCallout" HighlightCssClass="validatorCalloutHighlight" TargetControlID="RequiredFieldValidator64"
                        WarningIconImageUrl="~/images/Warning.png" Enabled="True" />
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="Label20" runat="server" Text="Calle: "></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="calleCli" runat="server" ValidationGroup="g1" MaxLength="80"></asp:TextBox>
                    <asp:FilteredTextBoxExtender ID="FilteredTextBoxExtender6" runat="server" FilterType="LowercaseLetters,UppercaseLetters,Custom,Numbers"
                        ValidChars=" .ñÑáéíóúÁÉÍÓÚ" TargetControlID="calleCli">
                    </asp:FilteredTextBoxExtender>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator26" runat="server" ControlToValidate="calleCli"
                        Display="None" ErrorMessage="Campo obligatorio" ForeColor="Red" ValidationGroup="g1"></asp:RequiredFieldValidator>
                    <asp:ValidatorCalloutExtender ID="RequiredFieldValidator26_ValidatorCalloutExtender"
                        runat="server" CloseImageUrl="~/images/close.gif" CssClass="validatorCallout"
                        Enabled="True" HighlightCssClass="validatorCalloutHighlight" TargetControlID="RequiredFieldValidator26"
                        WarningIconImageUrl="~/images/Warning.png" />
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="Label91" runat="server" Text="Número:"></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="txt_numero" runat="server" ValidationGroup="g1" MaxLength="20"></asp:TextBox>
                    <asp:FilteredTextBoxExtender ID="FilteredTextBoxExtender7" runat="server" FilterType="LowercaseLetters,Custom,Numbers,UppercaseLetters"
                            ValidChars=" -" TargetControlID="txt_numero">
                    </asp:FilteredTextBoxExtender>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator24" runat="server" ControlToValidate="txt_numero"
                        Display="None" ErrorMessage="Campo obligatorio" ForeColor="Red" ValidationGroup="g1"></asp:RequiredFieldValidator>
                    <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender85" runat="server" CloseImageUrl="~/images/close.gif"
                        CssClass="validatorCallout" Enabled="True" HighlightCssClass="validatorCalloutHighlight"
                        TargetControlID="RequiredFieldValidator24" WarningIconImageUrl="~/images/Warning.png" />
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="Label92" runat="server" Text="Colonia:"></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="txt_colonia" runat="server" ValidationGroup="g1" MaxLength="45"></asp:TextBox>
                    <asp:FilteredTextBoxExtender ID="FilteredTextBoxExtender8" runat="server" FilterType="LowercaseLetters,UppercaseLetters,Custom,Numbers"
                        TargetControlID="txt_colonia" ValidChars=" .-ñÑáéíóúÁÉÍÓÚ">
                    </asp:FilteredTextBoxExtender>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator9" runat="server" ControlToValidate="txt_colonia"
                        Display="None" ErrorMessage="Campo obligatorio" ForeColor="Red" ValidationGroup="g1"></asp:RequiredFieldValidator>
                    <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender84" runat="server" CloseImageUrl="~/images/close.gif"
                        CssClass="validatorCallout" Enabled="True" HighlightCssClass="validatorCalloutHighlight"
                        TargetControlID="RequiredFieldValidator9" WarningIconImageUrl="~/images/Warning.png" />
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="Label30" runat="server" Text="C.P.: "></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="cpCot" runat="server" ValidationGroup="g1" MaxLength="6"></asp:TextBox>
                    <asp:FilteredTextBoxExtender ID="FilteredTextBoxExtender5" runat="server" FilterType="Numbers"
                        TargetControlID="cpCot">
                    </asp:FilteredTextBoxExtender>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator27" runat="server" ControlToValidate="cpCot"
                        Display="None" ErrorMessage="Campo obligatorio" ForeColor="Red" ValidationGroup="g1"></asp:RequiredFieldValidator>
                    <asp:ValidatorCalloutExtender ID="RequiredFieldValidator27_ValidatorCalloutExtender"
                        runat="server" CloseImageUrl="~/images/close.gif" CssClass="validatorCallout"
                        Enabled="True" HighlightCssClass="validatorCalloutHighlight" TargetControlID="RequiredFieldValidator27"
                        WarningIconImageUrl="~/images/Warning.png" />
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="Label93" runat="server" Text="País:"></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="txt_pais" runat="server" ValidationGroup="g1" MaxLength="45"></asp:TextBox>
                    <asp:FilteredTextBoxExtender ID="FilteredTextBoxExtender9" runat="server" FilterType="LowercaseLetters,UppercaseLetters,Custom"
                        ValidChars=" .ñÑáéíóúÁÉÍÓÚ" TargetControlID="txt_pais">
                    </asp:FilteredTextBoxExtender>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator25" runat="server" ControlToValidate="txt_pais"
                        Display="None" ErrorMessage="Campo obligatorio" ForeColor="Red" ValidationGroup="g1"></asp:RequiredFieldValidator>
                    <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender86" runat="server" CloseImageUrl="~/images/close.gif"
                        CssClass="validatorCallout" Enabled="True" HighlightCssClass="validatorCalloutHighlight"
                        TargetControlID="RequiredFieldValidator25" WarningIconImageUrl="~/images/Warning.png" />
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="Label32" runat="server" Text="Estado: "></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="edocot" runat="server" ValidationGroup="g1" MaxLength="45"></asp:TextBox>
                    <asp:FilteredTextBoxExtender ID="FilteredTextBoxExtender10" runat="server" FilterType="LowercaseLetters,UppercaseLetters,Custom"
                        ValidChars=" .ñÑáéíóúÁÉÍÓÚ" TargetControlID="edocot">
                    </asp:FilteredTextBoxExtender>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator28" runat="server" ControlToValidate="edocot"
                        Display="None" ErrorMessage="Campo obligatorio" ForeColor="Red" ValidationGroup="g1"></asp:RequiredFieldValidator>
                    <asp:ValidatorCalloutExtender ID="RequiredFieldValidator28_ValidatorCalloutExtender"
                        runat="server" CloseImageUrl="~/images/close.gif" CssClass="validatorCallout"
                        Enabled="True" HighlightCssClass="validatorCalloutHighlight" TargetControlID="RequiredFieldValidator28"
                        WarningIconImageUrl="~/images/Warning.png" />
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="Label31" runat="server" Text="Ciudad: "></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="munCot" runat="server" ValidationGroup="g1" MaxLength="45"></asp:TextBox>
                    <asp:FilteredTextBoxExtender ID="munCli_FilteredTextBoxExtender" runat="server" FilterType="LowercaseLetters,UppercaseLetters,Custom"
                        TargetControlID="munCot" ValidChars=" .ñÑáéíóúÁÉÍÓÚ">
                    </asp:FilteredTextBoxExtender>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator29" runat="server" ControlToValidate="munCot"
                        Display="None" ErrorMessage="Campo obligatorio" ForeColor="Red" ValidationGroup="g1"></asp:RequiredFieldValidator>
                    <asp:ValidatorCalloutExtender ID="RequiredFieldValidator29_ValidatorCalloutExtender"
                        runat="server" CloseImageUrl="~/images/close.gif" CssClass="validatorCallout"
                        Enabled="True" HighlightCssClass="validatorCalloutHighlight" TargetControlID="RequiredFieldValidator29"
                        WarningIconImageUrl="~/images/Warning.png" />
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="lParentescoBen" runat="server" Text="Parentesco: " Visible="True"></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="parentescoBen" runat="server" Visible="True" ValidationGroup="g1" MaxLength="45"></asp:TextBox>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator66" runat="server" Display="None"
                        ControlToValidate="parentescoBen" ErrorMessage="Campo obligatorio" ForeColor="Red"
                        ValidationGroup="g1"></asp:RequiredFieldValidator>
                    <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender65" runat="server" CloseImageUrl="~/images/close.gif"
                        CssClass="validatorCallout" HighlightCssClass="validatorCalloutHighlight" TargetControlID="RequiredFieldValidator66"
                        WarningIconImageUrl="~/images/Warning.png" Enabled="True" />
                        <asp:FilteredTextBoxExtender ID="FilteredTextBoxExtender4" runat="server" FilterType="LowercaseLetters,UppercaseLetters,Custom"
                        TargetControlID="parentescoBen" ValidChars=" .ñÑáéíóú"/>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="lPorcentajeBen" runat="server" Text="Porcentaje: " Visible="True"></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="porcentajeBen" runat="server" Visible="True" ValidationGroup="g1" MaxLength="5"></asp:TextBox>
                    <asp:FilteredTextBoxExtender ID="porcentajeBen_FilteredTextBoxExtender" runat="server"
                        FilterType="Custom, Numbers" TargetControlID="porcentajeBen" ValidChars=".">
                    </asp:FilteredTextBoxExtender>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator67" runat="server" Display="None"
                        ControlToValidate="porcentajeBen" ErrorMessage="Campo obligatorio" ForeColor="Red"
                        ValidationGroup="g1"></asp:RequiredFieldValidator>
                    <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender66" runat="server" CloseImageUrl="~/images/close.gif"
                        CssClass="validatorCallout" HighlightCssClass="validatorCalloutHighlight" TargetControlID="RequiredFieldValidator67"
                        WarningIconImageUrl="~/images/Warning.png" Enabled="True" />
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator10" runat="server"
                        ControlToValidate="porcentajeBen" Display="None" ErrorMessage="Formato Incorrecto. Ejemplo 0.1"
                        ForeColor="Red" ValidationGroup="g1" ValidationExpression="^100$|^\d{0,2}(\.\d{1,2})? *%?$"></asp:RegularExpressionValidator>
                    <asp:ValidatorCalloutExtender ID="RegularExpressionValidator10_ValidatorCalloutExtender"
                        runat="Server" CloseImageUrl="~/images/close.gif" CssClass="validatorCallout"
                        HighlightCssClass="validatorCalloutHighlight" PopupPosition="Right" TargetControlID="RegularExpressionValidator10"
                        WarningIconImageUrl="~/images/Warning.png" />
                </td>
            </tr>
            <tr>
                <td>
                    &nbsp;
                </td>
                <td>
                    &nbsp;
                </td>
            </tr>
            <tr>
                <td colspan="2">
                    <asp:Button ID="btnRegistrarBen" runat="server" CssClass="button2" Text="Agregar"
                        ValidationGroup="g1" />
                    <asp:Button ID="btnModificarBen" runat="server" CssClass="button2" Text="Modificar" Visible="false"
                        ValidationGroup="g1" />
                    <asp:Button ID="btnCancelarBen" runat="server" CssClass="button2" Text="Cancelar"   
                        CausesValidation="false" />
                    <br />
                    <asp:Label ID="lb_error" runat="server" ForeColor="Red" Text=""></asp:Label>
                </td>
            </tr>
        </table>
    </center>
</div>
<p>
    &nbsp;</p>
<div style="width: 90%; margin-left: auto; margin-right: auto; padding-bottom: 15px;
    padding-left: 15px; padding-top: 15px; overflow: hidden;">
    <center>
        <table style="width: 100%;">
            <tr>
                <td align="left">
                    <asp:Button ID="btnRegresar2" runat="server" CssClass="button2" Text="Regresar" />
                </td>
                <td align="right">
                    <asp:Button ID="btnSiguiente3" runat="server" CssClass="button2" Text="Siguiente"
                        Height="26px" />
                </td>
            </tr>
        </table>
    </center>
</div>
